export const request = (params) => {

    const baseUrl = 'http://api_dev.wanxikeji.cn/api'

    return new Promise((resolve, reject) => {
        wx.request({
            ...params,
            method: "POST", //请求方法
            header: { //请求头
                "content-type": "application/json"
            },
            url: baseUrl + params.url,
            success: (res) => {
                resolve(res)
            },
            fail: (err) => {
                reject(err)
            },
        })
    })
}